<template>
	<view v-html="conten">

	</view>
</template>

<script setup>
	import {
		ref
	} from 'vue';
	import {
		onLoad
	} from '@dcloudio/uni-app'
	import {
		getAgreement
	} from '@/common/http.api.js';
	
	const conten = ref('')
	onLoad((option) => {
		if(option.type == '4'){
			uni.setNavigationBarTitle({
				title:'平台协议'
			})
			getAgreement({id:option.type}).then(res=>{
				conten.value = res.data.agreement_system
			})
		}else if(option.type == '2'){
			uni.setNavigationBarTitle({
				title:'用户协议'
			})
			getAgreement({id:option.type}).then(res=>{
				conten.value = res.data.agreement_user
			})
		}else if(option.type == '3'){
			uni.setNavigationBarTitle({
				title:'入圈协议'
			})
			getAgreement({id:option.type}).then(res=>{
				conten.value = res.data.agreement_join_circle
			})
		}
		
	})
</script>

<style lang="scss">
	page {
		width: 100%;
		padding: 20rpx;
		font-size: 30rpx;
		box-sizing: border-box;
	}
</style>